﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class student_paper : System.Web.UI.Page
{
    protected Student stu;
    protected void Page_Load(object sender, EventArgs e)
    {
        stu = Student.Check();
        if (stu == null)
        {
            Session.Add(Params.SystemError, "请先登录");
            Response.Redirect(Params.RootHttp + "default.aspx");
        }
        if (!Page.IsPostBack)
        {
            this.MyDataBind();
        }
    }

    public void MyDataBind()
    {
        this.Title = this.stu.RealName + "-我的论文-" + this.stu.PaperName;
        this.conNav.Title = "我的论文";
        string sql = "select Guid from Paper where StudentGuid=" + this.stu.Guid.ToString() + " order by Guid asc";
        DataTable dt = Fun.CreateDt(sql);
        this.repPapers.DataSource = dt;
        this.repPapers.DataBind();
    }
    protected void btnWrite_Click(object sender, EventArgs e)
    {
        Response.Redirect("write.aspx?uid=" + Request.Params["uid"] + "&recvers="+this.stu.ExpertGuid.ToString());
    }
}
